Optimal. Leaf size=302 \[ \frac {6 B^2 n^2 (b c-a d) \text {Li}_2\left (\frac {(d g-c h) (a+b x)}{(b g-a h) (c+d x)}\right ) \left (B \log \left (e (a+b x)^n (c+d x)^{-n}\right )+A\right )}{(b g-a h) (d g-c h)}+\frac {3 B n (b c-a d) \log \left (1-\frac {(a+b x) (d g-c h)}{(c+d x) (b g-a h)}\right ) \left (B \log \left (e (a+b x)^n (c+d x)^{-n}\right )+A\right )^2}{(b g-a h) (d g-c h)}+\frac {(a+b x) \left (B \log \left (e (a+b x)^n (c+d x)^{-n}\right )+A\right )^3}{(g+h x) (b g-a h)}-\frac {6 B^3 n^3 (b c-a d) \text {Li}_3\left (\frac {(d g-c h) (a+b x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)} \]
[Out]
________________________________________________________________________________________
Rubi [B] time = 0.81, antiderivative size = 650, normalized size of antiderivative = 2.15, number of steps used = 14, number of rules used = 9, integrand size = 33, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.273, Rules used = {6742, 2490, 36, 31, 2503, 2502, 2315, 2506, 6610} \[ \frac {6 A B^2 n^2 (b c-a d) \text {PolyLog}\left (2,1-\frac {(g+h x) (b c-a d)}{(c+d x) (b g-a h)}\right )}{(b g-a h) (d g-c h)}+\frac {6 B^3 n^2 (b c-a d) \log \left (e (a+b x)^n (c+d x)^{-n}\right ) \text {PolyLog}\left (2,1-\frac {(g+h x) (b c-a d)}{(c+d x) (b g-a h)}\right )}{(b g-a h) (d g-c h)}-\frac {6 B^3 n^3 (b c-a d) \text {PolyLog}\left (3,1-\frac {(g+h x) (b c-a d)}{(c+d x) (b g-a h)}\right )}{(b g-a h) (d g-c h)}+\frac {3 A^2 B (a+b x) \log \left (e (a+b x)^n (c+d x)^{-n}\right )}{(g+h x) (b g-a h)}-\frac {3 A^2 B n (b c-a d) \log (c+d x)}{(b g-a h) (d g-c h)}+\frac {3 A^2 B n (b c-a d) \log (g+h x)}{(b g-a h) (d g-c h)}+\frac {3 A B^2 (a+b x) \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right )}{(g+h x) (b g-a h)}+\frac {6 A B^2 n (b c-a d) \log \left (e (a+b x)^n (c+d x)^{-n}\right ) \log \left (\frac {(g+h x) (b c-a d)}{(c+d x) (b g-a h)}\right )}{(b g-a h) (d g-c h)}+\frac {B^3 (a+b x) \log ^3\left (e (a+b x)^n (c+d x)^{-n}\right )}{(g+h x) (b g-a h)}+\frac {3 B^3 n (b c-a d) \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right ) \log \left (\frac {(g+h x) (b c-a d)}{(c+d x) (b g-a h)}\right )}{(b g-a h) (d g-c h)}-\frac {A^3}{h (g+h x)} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 31
Rule 36
Rule 2315
Rule 2490
Rule 2502
Rule 2503
Rule 2506
Rule 6610
Rule 6742
Rubi steps
\begin {align*} \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^3}{(g+h x)^2} \, dx &=\int \left (\frac {A^3}{(g+h x)^2}+\frac {3 A^2 B \log \left (e (a+b x)^n (c+d x)^{-n}\right )}{(g+h x)^2}+\frac {3 A B^2 \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right )}{(g+h x)^2}+\frac {B^3 \log ^3\left (e (a+b x)^n (c+d x)^{-n}\right )}{(g+h x)^2}\right ) \, dx\\ &=-\frac {A^3}{h (g+h x)}+\left (3 A^2 B\right ) \int \frac {\log \left (e (a+b x)^n (c+d x)^{-n}\right )}{(g+h x)^2} \, dx+\left (3 A B^2\right ) \int \frac {\log ^2\left (e (a+b x)^n (c+d x)^{-n}\right )}{(g+h x)^2} \, dx+B^3 \int \frac {\log ^3\left (e (a+b x)^n (c+d x)^{-n}\right )}{(g+h x)^2} \, dx\\ &=-\frac {A^3}{h (g+h x)}+\frac {3 A^2 B (a+b x) \log \left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {3 A B^2 (a+b x) \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {B^3 (a+b x) \log ^3\left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}-\frac {\left (3 A^2 B (b c-a d) n\right ) \int \frac {1}{(c+d x) (g+h x)} \, dx}{b g-a h}-\frac {\left (6 A B^2 (b c-a d) n\right ) \int \frac {\log \left (e (a+b x)^n (c+d x)^{-n}\right )}{(c+d x) (g+h x)} \, dx}{b g-a h}-\frac {\left (3 B^3 (b c-a d) n\right ) \int \frac {\log ^2\left (e (a+b x)^n (c+d x)^{-n}\right )}{(c+d x) (g+h x)} \, dx}{b g-a h}\\ &=-\frac {A^3}{h (g+h x)}+\frac {3 A^2 B (a+b x) \log \left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {3 A B^2 (a+b x) \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {B^3 (a+b x) \log ^3\left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {6 A B^2 (b c-a d) n \log \left (e (a+b x)^n (c+d x)^{-n}\right ) \log \left (\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}+\frac {3 B^3 (b c-a d) n \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right ) \log \left (\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}-\frac {\left (3 A^2 B d (b c-a d) n\right ) \int \frac {1}{c+d x} \, dx}{(b g-a h) (d g-c h)}+\frac {\left (3 A^2 B (b c-a d) h n\right ) \int \frac {1}{g+h x} \, dx}{(b g-a h) (d g-c h)}-\frac {\left (6 A B^2 (b c-a d)^2 n^2\right ) \int \frac {\log \left (-\frac {(-b c+a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(a+b x) (c+d x)} \, dx}{(b g-a h) (d g-c h)}-\frac {\left (6 B^3 (b c-a d)^2 n^2\right ) \int \frac {\log \left (e (a+b x)^n (c+d x)^{-n}\right ) \log \left (-\frac {(-b c+a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(a+b x) (c+d x)} \, dx}{(b g-a h) (d g-c h)}\\ &=-\frac {A^3}{h (g+h x)}-\frac {3 A^2 B (b c-a d) n \log (c+d x)}{(b g-a h) (d g-c h)}+\frac {3 A^2 B (a+b x) \log \left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {3 A B^2 (a+b x) \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {B^3 (a+b x) \log ^3\left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {3 A^2 B (b c-a d) n \log (g+h x)}{(b g-a h) (d g-c h)}+\frac {6 A B^2 (b c-a d) n \log \left (e (a+b x)^n (c+d x)^{-n}\right ) \log \left (\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}+\frac {3 B^3 (b c-a d) n \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right ) \log \left (\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}+\frac {6 B^3 (b c-a d) n^2 \log \left (e (a+b x)^n (c+d x)^{-n}\right ) \text {Li}_2\left (1-\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}+\frac {\left (6 A B^2 (b c-a d)^2 n^2\right ) \operatorname {Subst}\left (\int \frac {\log \left (-\frac {(-b c+a d) x}{b g-a h}\right )}{1+\frac {(-b c+a d) x}{b g-a h}} \, dx,x,\frac {g+h x}{c+d x}\right )}{(b g-a h)^2 (d g-c h)}-\frac {\left (6 B^3 (b c-a d)^2 n^3\right ) \int \frac {\text {Li}_2\left (1+\frac {(-b c+a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(a+b x) (c+d x)} \, dx}{(b g-a h) (d g-c h)}\\ &=-\frac {A^3}{h (g+h x)}-\frac {3 A^2 B (b c-a d) n \log (c+d x)}{(b g-a h) (d g-c h)}+\frac {3 A^2 B (a+b x) \log \left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {3 A B^2 (a+b x) \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {B^3 (a+b x) \log ^3\left (e (a+b x)^n (c+d x)^{-n}\right )}{(b g-a h) (g+h x)}+\frac {3 A^2 B (b c-a d) n \log (g+h x)}{(b g-a h) (d g-c h)}+\frac {6 A B^2 (b c-a d) n \log \left (e (a+b x)^n (c+d x)^{-n}\right ) \log \left (\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}+\frac {3 B^3 (b c-a d) n \log ^2\left (e (a+b x)^n (c+d x)^{-n}\right ) \log \left (\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}+\frac {6 A B^2 (b c-a d) n^2 \text {Li}_2\left (1-\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}+\frac {6 B^3 (b c-a d) n^2 \log \left (e (a+b x)^n (c+d x)^{-n}\right ) \text {Li}_2\left (1-\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}-\frac {6 B^3 (b c-a d) n^3 \text {Li}_3\left (1-\frac {(b c-a d) (g+h x)}{(b g-a h) (c+d x)}\right )}{(b g-a h) (d g-c h)}\\ \end {align*}
________________________________________________________________________________________
Mathematica [F] time = 3.13, size = 0, normalized size = 0.00 \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^3}{(g+h x)^2} \, dx \]
Verification is Not applicable to the result.
[In]
[Out]
________________________________________________________________________________________
fricas [F] time = 0.82, size = 0, normalized size = 0.00 \[ {\rm integral}\left (\frac {B^{3} \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right )^{3} + 3 \, A B^{2} \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right )^{2} + 3 \, A^{2} B \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right ) + A^{3}}{h^{2} x^{2} + 2 \, g h x + g^{2}}, x\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {{\left (B \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right ) + A\right )}^{3}}{{\left (h x + g\right )}^{2}}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [F] time = 3.36, size = 0, normalized size = 0.00 \[ \int \frac {\left (B \ln \left (e \left (b x +a \right )^{n} \left (d x +c \right )^{-n}\right )+A \right )^{3}}{\left (h x +g \right )^{2}}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \[ \frac {B^{3} \log \left ({\left (d x + c\right )}^{n}\right )^{3}}{h^{2} x + g h} + \frac {3 \, {\left (\frac {b e n \log \left (b x + a\right )}{b g h - a h^{2}} - \frac {d e n \log \left (d x + c\right )}{d g h - c h^{2}} - \frac {{\left (b c e n - a d e n\right )} \log \left (h x + g\right )}{{\left (d g h - c h^{2}\right )} a - {\left (d g^{2} - c g h\right )} b}\right )} A^{2} B}{e} - \frac {3 \, A^{2} B \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right )}{h^{2} x + g h} - \frac {A^{3}}{h^{2} x + g h} + \int \frac {B^{3} c h \log \relax (e)^{3} + 3 \, A B^{2} c h \log \relax (e)^{2} + {\left (B^{3} d h x + B^{3} c h\right )} \log \left ({\left (b x + a\right )}^{n}\right )^{3} + 3 \, {\left (B^{3} c h \log \relax (e) + A B^{2} c h + {\left (B^{3} d h \log \relax (e) + A B^{2} d h\right )} x\right )} \log \left ({\left (b x + a\right )}^{n}\right )^{2} + 3 \, {\left (A B^{2} c h - {\left (d g n - c h \log \relax (e)\right )} B^{3} - {\left ({\left (h n - h \log \relax (e)\right )} B^{3} d - A B^{2} d h\right )} x + {\left (B^{3} d h x + B^{3} c h\right )} \log \left ({\left (b x + a\right )}^{n}\right )\right )} \log \left ({\left (d x + c\right )}^{n}\right )^{2} + {\left (B^{3} d h \log \relax (e)^{3} + 3 \, A B^{2} d h \log \relax (e)^{2}\right )} x + 3 \, {\left (B^{3} c h \log \relax (e)^{2} + 2 \, A B^{2} c h \log \relax (e) + {\left (B^{3} d h \log \relax (e)^{2} + 2 \, A B^{2} d h \log \relax (e)\right )} x\right )} \log \left ({\left (b x + a\right )}^{n}\right ) - 3 \, {\left (B^{3} c h \log \relax (e)^{2} + 2 \, A B^{2} c h \log \relax (e) + {\left (B^{3} d h x + B^{3} c h\right )} \log \left ({\left (b x + a\right )}^{n}\right )^{2} + {\left (B^{3} d h \log \relax (e)^{2} + 2 \, A B^{2} d h \log \relax (e)\right )} x + 2 \, {\left (B^{3} c h \log \relax (e) + A B^{2} c h + {\left (B^{3} d h \log \relax (e) + A B^{2} d h\right )} x\right )} \log \left ({\left (b x + a\right )}^{n}\right )\right )} \log \left ({\left (d x + c\right )}^{n}\right )}{d h^{3} x^{3} + c g^{2} h + {\left (2 \, d g h^{2} + c h^{3}\right )} x^{2} + {\left (d g^{2} h + 2 \, c g h^{2}\right )} x}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [F] time = 0.00, size = -1, normalized size = -0.00 \[ \int \frac {{\left (A+B\,\ln \left (\frac {e\,{\left (a+b\,x\right )}^n}{{\left (c+d\,x\right )}^n}\right )\right )}^3}{{\left (g+h\,x\right )}^2} \,d x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________